/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */
package com.qdu.servlet;

import com.qdu.entity.Admin;
import com.qdu.entity.User;
import com.qdu.util.DatabaseUtil;
import java.io.IOException;
import java.io.PrintWriter;
import java.sql.Connection;
import java.sql.PreparedStatement;
import java.sql.SQLException;
import javax.servlet.ServletException;
import javax.servlet.annotation.WebServlet;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import javax.servlet.http.HttpSession;

/**
 *
 * @author Sanshi
 */
@WebServlet("/rss")
public class RmoveSessionServlet extends HttpServlet {
 @Override
    protected void doPost(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException {

        //获取新注册的学生的信息，封装成一个学生对象
        req.setCharacterEncoding("utf-8");
   HttpSession session = req.getSession();
   session.invalidate();
   req.getRequestDispatcher("/userLog.jsp").forward(req, resp);
     
}
}